package com.ytxg.health_management.mapper;

import com.ytxg.health_management.pojo.dto.UserDto;
import com.ytxg.health_management.pojo.entity.User;
import com.ytxg.health_management.pojo.entity.UserIp;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface UserMapper {
    /**
     * 注册用户
     * @param user
     * @return int
     */
    int register(User user);

    String getUserName(String username);


    User getUserInfo(String userName);

    int updatePsw(String userName, String password);
    List<UserDto> getAll(User user);
    int getCountAll(User user);

    UserIp selectIp(int id);
    int updateImg(String img,int id);
    int updateUser(User user);
    int deleteUser(User user);
}
